<template>
  <view class="my-container">
    <!-- 登陆组件 -->
    <my-login v-if="!token"></my-login>
    <!-- 用户信息组件 -->
    <my-userinfo v-else></my-userinfo>
  </view>
</template>

<script>
  // 导入设置tabbar 购物车徽标的mixin
  import badgeMixin from '@/mixins/tabbar-badge.js'
  // 导入mapState 辅助函数
  import { mapState } from 'vuex'
  
  export default {
    
    name: 'myInfo',
    mixins: [badgeMixin],
    data() {
      return {}
    },
    computed: { ...mapState('m_user', ['token']) },
    methods: {}
  }
</script>

<style lang="scss">
  page,
  .my-container {
    height: 100%;
  }
  

</style>
